package myCommunity.web.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import myCommunity.biz.impl.CommunityForumBizImpl;

@Controller
public class HomeController {
	@Autowired
	private CommunityForumBizImpl forumbiz;
	
	@RequestMapping("/index")
	public String index(Model model){
		model.addAttribute("forumList1",forumbiz.fetchByParentId(1));
		model.addAttribute("forumList2",forumbiz.fetchByParentId(2));
		return "index";
	}
	@RequestMapping("/login")
	public String login(Model model){

		return "login";
	}

}
